//
//  MineCell.swift
//  Xiaozihui
//
//  Created by 校企荟 on 2017/8/31.
//  Copyright © 2017年 校企荟. All rights reserved.
//

import UIKit

class MineCell: UITableViewCell {

    lazy var iconIV: UIImageView = {
        let iv = UIImageView()
        return iv
    }()
    
    lazy var titleLbl: UILabel = {
        return UILabel(content: "编辑个人资料", textFont: UIFont.systemFont(ofSize: 16 * ScaleX), color:mainColor, alignment: .center, numberOfLine: 1)
    }()
    
    lazy var indicatorView: UIImageView = {
        let iv = UIImageView()
        return iv
    }()
    
    override init(style: UITableViewCellStyle, reuseIdentifier: String?) {
        super.init(style: style, reuseIdentifier: reuseIdentifier)
        contentView.addSubview(iconIV)
        contentView.addSubview(titleLbl)
        contentView.addSubview(indicatorView)
        
        iconIV.snp.makeConstraints { (make) in
            make.left.equalTo(contentView).offset(27)
            make.centerY.equalTo(contentView)
        }
        
        titleLbl.snp.makeConstraints { (make) in
            make.left.equalTo(iconIV.snp.right).offset(12)
            make.centerY.equalTo(contentView)
            make.top.equalTo(contentView).offset(26)
            make.bottom.equalTo(contentView).offset(-26)
        }
        
        indicatorView.snp.makeConstraints { (make) in
            make.right.equalTo(contentView).offset(-15)
            make.centerY.equalTo(contentView)
        }
        
        let lineView = UIView()
        lineView.backgroundColor = #colorLiteral(red: 0.937254902, green: 0.8745098039, blue: 0.8823529412, alpha: 1)
        contentView.addSubview(lineView)
        lineView.snp.makeConstraints { (make) in
            make.left.right.bottom.equalTo(contentView)
            make.height.equalTo(1)
        }
        
    }
    
    required init?(coder aDecoder: NSCoder) {
        fatalError("init(coder:) has not been implemented")
    }
    
    
    override func awakeFromNib() {
        super.awakeFromNib()
        // Initialization code
    }

    override func setSelected(_ selected: Bool, animated: Bool) {
        super.setSelected(selected, animated: animated)

        // Configure the view for the selected state
    }

}
